<template>
  <Suspense>
    <template #default>
      <AsyncComponent />
    </template>
    <template #fallback>
      <div>加载中...</div>
    </template>
  </Suspense>
</template>
<script setup lang="ts">
import { defineAsyncComponent } from 'vue'
console.log('开始加载...')
const AsyncComponent = defineAsyncComponent({ loader: () => import('@/components/AsyncComponent.vue'), delay: 1000 })
</script>
<style lang="scss" scoped></style>
